<?php
$currentController = Zend_Controller_Front::getInstance()->getRequest()->getControllerName();
$currentAction = Zend_Controller_Front::getInstance()->getRequest()->getActionName();
#echo $this->doctype(); ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<?php if ($this->layout()->userLanguage == 'sp') {
$lang =  "xml:lang=\"sp-es\" lang=\"sp-es\"";
} elseif ($this->layout()->userLanguage == 'fr') {
$lang =  "xml:lang=\"fr-FR\" lang=\"fr-FR\"";
} else {
$lang =  "xml:lang=\"en-gb\" lang=\"en-gb\"";
}
?>
<html xmlns="http://www.w3.org/1999/xhtml" <?php echo $lang ?> >
<head>
<?php
echo $this->headTitle() . "\n";
echo $this->headMeta() . "\n";
echo $this->headLink()->setStylesheet($this->baseUrl() . '/css/style.css')
 						->headLink(array('rel' => 'favicon',
                                 'href' => '/img/favicon.ico'),
                                  'PREPEND') . "\n";
echo $this->headLink()->setStylesheet('/css/slider.css') . "\n";
echo $this->headLink()->setStylesheet('/css/jquery.cursorMessage.css') . "\n";


?>
<meta name="robots" content="index, follow" />
<link href="/images/favicon.ico" rel="shortcut icon" type="image/x-icon" />
<meta name="description" content="<?php if($this->seotranslation('description') != "") { echo $this->seotranslation('description'); } else {echo $this->translatex('DEFAULT_META_DESCRIPTION');} ?>" />
<meta name="keywords" content="<?php echo $this->translatex('DEFAULT_META_KEYWORDS'); ?>" />

<?php if($this->layout()->askAge) { ?>
<link rel="stylesheet" href="/css/GMStyles.css" media="all" />
<script type="text/javascript" src="/scripts/jquery-1.5.2.min.js"></script>
<script type="text/javascript" src="/scripts/jquery.easing.1.3.js"></script>
<script type="text/javascript" src="/scripts/observable.js"> </script>
<script type="text/javascript" src="/scripts/fauxfields.js"> </script>
<script type="text/javascript" src="/scripts/scroll.js"> </script>
<script type="text/javascript" src="/scripts/scripts.js"> </script>
<link href="/css/style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="/scripts/jquery.ezmark.min.js"></script>
<script type="text/javascript" src="/scripts/cufon-yui.js"></script>
<script type="text/javascript" src="/scripts/Helvetica_Neue_200.font.js"></script>
<script type="text/javascript" src="/scripts/thickbox.js"></script>
<script type="text/javascript" src="/scripts/jquery.checkbox.js"></script>
<script type="text/javascript" src="/scripts/browserDetect-min.js"></script>
<link rel="stylesheet" href="/css/thickbox.css" type="text/css" media="screen" />
<link rel="stylesheet" href="/css/jquery.checkbox.css" type="text/css" media="screen" />
<?php } else {?>
<script type="text/javascript" src="/scripts/jquery-1.5.2.min.js"></script>
<script type="text/javascript" src="/scripts/jquery-ui-1.8.11.custom.min.js"></script>
<script type="text/javascript" src="/scripts/jquery.easing.1.3.js"></script>
<script type="text/javascript" src="/scripts/jquery.selectbox-0.5.js"></script>
<script type="text/javascript" src="/scripts/cufon-yui.js"></script>
<script type="text/javascript" src="/scripts/Helvetica_Neue_100.font.js"></script>
<script type="text/javascript" src="/scripts/browserDetect-min.js"></script>
<script type="text/javascript" src="/scripts/thickbox.js"></script>
<link rel="stylesheet" href="/css/thickbox.css" type="text/css" media="screen" />

<?php if ($currentController === "sunsethours" && $currentAction === "saveimage") { ?>
<script type="text/javascript" src="/scripts/jquery.ezmark.min.js"></script>
<?php } ?>

<?php if ($currentController === "sunsethours" && $currentAction === "cropimage") { ?>
<script type="text/javascript" src="/scripts/jquery.Jcrop.min.js"></script>
<?php } ?>

<?php if ($currentController === "aboutus" && $currentAction === "history") { ?>
<script type="text/javascript" src="/scripts/history.js"></script>
<?php } ?>

<?php if ($currentController === "collection" && $currentAction === "limitededition") { ?>
<script type="text/javascript" src="/scripts/history.js"></script>
<?php } ?>

<script type="text/javascript">
$(document).ready(function() {
<?php if ($currentController === "sunsethours" && $currentAction === "saveimage") { ?>
	$(function() {
		$('input[type=checkbox]').ezMark()
	});
<?php } ?>

/*SELECTBOX*/
	$('#residenceCountry').selectbox();
	$('#language').selectbox();
	$('#day').selectbox();
	$('#month').selectbox();
	$('#year').selectbox();
	$('#country_o_r').selectbox();
	$('#country').selectbox();

/*COUNTRY SELECT*/
	$('#country_input').click(function(){
		$('#country_container').slideDown(250);
		$('#country_container').hover(
			function () {
				$('#country_container').slideDown(250);
			},
			function () {
				$('#country_container').slideUp(250);
			}
		);
	});
/*DROPDOWN MENU*/
	$('.mainNav .firstLevel li a').each(function(index) {
			if($(this).hasClass('selected')){
					$(this).parent().find('.secondLevel').stop(true, true).fadeIn(50);
			}
  });
	$('.mainNav .firstLevel li').hover(
			function () {
				$(this).find('.secondLevel').stop(true, true).fadeIn(500);
			},
			function () {
					$(this).find('.secondLevel').hover(
							function () {
									$(this).find('.secondLevel').toggle('hover');
							},
							function () {
									$(this).find('.secondLevel').toggle('hover');
							}
					);
					if(!$(this).find('.secondLevel').hasClass('hover') && !$(this).find('a').hasClass('selected')){
							$(this).find('.secondLevel').stop(true, true).fadeOut(500);
					}
			}
	);

/*FADE PRODUCT*/
/*	$('.next').click(function(){
		$('.drinkWrapper').fadeTo(400,0)
	});
	$('.prev').click(function(){
		$('.drinkWrapper').fadeTo(400,0)
	});
	$('.next').click(function(){
		$('.dessertWrapper').fadeTo(400,0)
	});
	$('.prev').click(function(){
		$('.dessertWrapper').fadeTo(400,0)
	});*/

<?php if ($currentController === "sunsethours" && $currentAction === "uploadimage") { ?>
$('input[type=file]').each(function(){
	var uploadbuttonlabeltext = $(this).attr('title');
	if(uploadbuttonlabeltext == ''){
		var uploadbuttonlabeltext = 'Browse';
	}
	var uploadbutton = '<div  class="browseButton"><?php echo $this->translatex('SH_UPLOAD_BROWSE'); ?></div>';
	$(this).wrap('<div class="fileinputs"></div>');
	$(this).addClass('file').css('opacity', 0).attr('size',23); //set to invisible
	$(this).parent().append($('<div class="fakefile" />').append($('<input type="text" class="fakeFileInput" />').attr('value',$(this).val()).attr('id',$(this).attr('id')+'__fake')).append(uploadbutton));
	$(this).bind('change', function() {
		$('#'+$(this).attr('id')+'__fake').val($(this).val());;
	});
	$(this).bind('mouseout', function() {
		$('#'+$(this).attr('id')+'__fake').val($(this).val());;
	});
});
<?php } ?>
/*CUFON*/
Cufon.replace('.headerWrapper .news,.headerWrapper .country,.firstLevel a.cufon,.sunsetLinks span,.sunsetTitle,.latestNews .cufon,.cufon,.browseButton.cufon', { fontFamily: 'Helvetica Neue', hover: true});

/*HOVER*/
$(".sunsetLinks").hover(
	function () {
		$(this).children().children("span").find("strong").stop(true, true).animate({opacity:"1"},{duration:300});
		$(this).children().children(".sunsetDescription").stop(true, true).animate({opacity:"1"},{duration:800});
	},
	function () {
		$(this).children().children("span").find("strong").stop(true, true).animate({opacity:"0.5"},{duration:300});
		$(this).children().children(".sunsetDescription").stop(true, true).animate({opacity:"0"},{duration:800});
	}
);
$("#cocktailsLink").hover(
		function () {
			$("#cocktailsLink span").stop(true, true).animate({opacity:"1"},{duration:300});
			$("#cocktails").stop(true, true).fadeIn(800);
		},
		function () {
			$("#cocktailsLink span").stop(true, true).animate({opacity:"0.5"},{duration:300});
			$("#cocktails").stop(true, true).fadeOut(800);
		}
	);
	$("#longDrinksLink").hover(
		function () {
			$("#longDrinksLink span").stop(true, true).animate({opacity:"1"},{duration:300});
			$("#longDrinks").stop(true, true).fadeIn(800);
		},
		function () {
			$("#longDrinksLink span").stop(true, true).animate({opacity:"0.5"},{duration:300});
			$("#longDrinks").stop(true, true).fadeOut(800);
		}
	);
	$("#otherDrinksLink").hover(
		function () {
			$("#otherDrinksLink span").stop(true, true).animate({opacity:"1"},{duration:300});
			$("#otherDrinks").stop(true, true).fadeIn(800);
		},
		function () {
			$("#otherDrinksLink span").stop(true, true).animate({opacity:"0.5"},{duration:300});
			$("#otherDrinks").stop(true, true).fadeOut(800);
		}
	);
$("#cocktailsArea").hover(
		function () {
			$("#cocktailsLink span").stop(true, true).animate({opacity:"1"},{duration:300});
			$("#cocktails").stop(true, true).fadeIn(800);
		},
		function () {
			$("#cocktailsLink span").stop(true, true).animate({opacity:"0.5"},{duration:300});
			$("#cocktails").stop(true, true).fadeOut(800);
		}
	);
	$("#longDrinksArea").hover(
		function () {
			$("#longDrinksLink span").stop(true, true).animate({opacity:"1"},{duration:300});
			$("#longDrinks").stop(true, true).fadeIn(800);
		},
		function () {
			$("#longDrinksLink span").stop(true, true).animate({opacity:"0.5"},{duration:300});
			$("#longDrinks").stop(true, true).fadeOut(800);
		}
	);
	$("#otherDrinksArea").hover(
		function () {
			$("#otherDrinksLink span").stop(true, true).animate({opacity:"1"},{duration:300});
			$("#otherDrinks").stop(true, true).fadeIn(800);
		},
		function () {
			$("#otherDrinksLink span").stop(true, true).animate({opacity:"0.5"},{duration:300});
			$("#otherDrinks").stop(true, true).fadeOut(800);
		}
	);
	$("#historyLink").hover(
		function () {
			$("#history").stop(true, true).fadeIn(800);
		},
		function () {
			$("#history").stop(true, true).fadeOut(800);
		}
	);
	$("#elaborationLink").hover(
		function () {
			$("#elaboration").stop(true, true).fadeIn(800);
		},
		function () {
			$("#elaboration").stop(true, true).fadeOut(800);
		}
	);

});
</script>
<?php
}
?>
<?php if($this->layout()->askAge) { echo $this->render('_agecheckerjs.phtml');} ?>

</head>

<body>
<div id="loader"></div>
<?php if($this->layout()->country == "FR" || (!$this->layout()->country && $this->layout()->userLanguage == "fr")) { ?>
<!--
Début de DoubleClick Floodlight Tag : ne supprimez pas
le nom d'activité de ce tag : Grand Marnier - HP
URL de la page Web où le tag doit être placé : http://fr.grand-marnier.com/
Ce tag doit être placé entre les tags <body> et </body>, le plus près possible du tag d'ouverture.
Date de création : 06/23/2011
-->
<script type="text/javascript">
var axel = Math.random() + "";
var a = axel * 10000000000000;
document.write('<iframe src="http://fls.doubleclick.net/activityi;src=3154543;type=grand449;cat=grand866;ord=1;num=' + a + '?" width="1" height="1" frameborder="0" style="display:none"></iframe>');
</script>
<noscript>
<iframe src="http://fls.doubleclick.net/activityi;src=3154543;type=grand449;cat=grand866;ord=1;num=1?" width="1" height="1" frameborder="0" style="display:none"></iframe>
</noscript>
<!-- Fin de DoubleClick Floodlight Tag : ne supprimez pas -->
<?php } ?>
<?php if($this->layout()->askAge) { echo $this->render('_agechecker.phtml');} ?>
          <?php foreach ($this->layout()->countriesSelect as $key => $value) {
              if ($this->layout()->country != "") {
              if ($key == $this->layout()->country) {
                  $country = $value;
              }
              } else {
                  $country = "France";
              }
          }
?>

<div class="bigWrapper">
	<div class="headerWrapper">
  	<div class="header">
    	<a class="news" href="<?php #echo $this->url(array('controller' => 'index', 'action' => 'news'), null, true) ?>"><?php #echo strtoupper($this->translatex('HOMEPAGE_ACTUALITY_TITLE')); ?></a>
      <div id="country_input" class="selectbox" tabindex="0"><?php echo $country ?></div>
      <div id="country_container" class="selectbox-wrapper" style="display: none;">
      	<ul>
          <?php foreach ($this->countriesdropdown() as $key => $value) { ?>
              <li id="country_input_fr" class=""><a href="/agechecker/setcountry/country/<?php echo $value['code_country'] ?>"><?php echo $value['name'] ?></a></li>
          <?php } ?>
        </ul>
      </div>
      <span class="country"><?php echo strtoupper($this->translatex('FAQ_COUNTRY')); ?></span>
    </div>
    <a class="logo" href="/"></a>
  </div>
  <div class="menuWrapper">
  			<?php echo $this->render('_topnav.phtml') ?>
  </div>

 <?php if ($currentController === "sunsethours" && $currentAction === "wall") { ?>
  <script type="text/javascript" src="/scripts/jquery.cursorMessage.js"></script>
  <script type="text/javascript" src="/scripts/slider.js"></script>
 <?php } else if ($currentController === "sunsethours" && ($currentAction === "uploadimage" || $currentAction === "takerapp" || $currentAction === "index")) { ?>
  <script type="text/javascript" src="/scripts/slider.js"></script>
 <?php } ?>

  <div class="contentWrapper">
  	<?php echo $this->layout()->content ?>
  </div>
  <div class="footerWrapper">
   <?php if ($this->layout()->showLatestNews) { ?>
    <div class="latestNews" style="visibility: hidden">
    	<span  class="cufon"><?php echo strtoupper($this->translatex('HOMEPAGE_LATEST_NEWS')); ?></span>
      	<span class="text"><?php echo $this->layout()->latestNewsShort; ?></span>
      	<a href="<?php echo $this->url(array('controller' => 'index', 'action' => 'news'), null, true) ?>">&nbsp;</a>
    </div>
   <?php } ?>
    <div class="bottomNav">
    	<ul>
      	<li><a href="<?php echo $this->url(array('controller' => 'index', 'action' => 'contactus'), null, true) ?>"><?php echo $this->translatex('SH_CONTACT_US'); ?></a></li>
      	<li><a href="<?php echo $this->url(array('controller' => 'index', 'action' => 'links'), null, true) ?>"><?php echo $this->translatex('FOOTER_LINKS'); ?></a></li>
      	<li><a href="<?php echo $this->prolink(); ?>"><?php echo $this->translatex('GM_PRO'); ?></a></li>
      	<li><a href="http://grandmarnierliqueur.yuku.com/" target="_blank"><?php echo $this->translatex('FORUM_TITLE'); ?></a></li>
      	<li><a href="/info/tandc" class="thickbox"><?php echo $this->translatex('FOOTER_LEGAL_TERMS'); ?></a></li>
      	<li><a href="/info/privacypolicy" class="thickbox"><?php echo $this->translatex('LEGAL_TERMS_FOOTER_TITLE'); ?></a></li>
      </ul>
      <div class="message"><?php echo $this->translatex('SH_FOOTER_DISCL'); ?></div>
    </div>
  </div>
</div>

	<script type="text/javascript">
		<!--
		xtnv = document;        //parent.document or top.document or document
		xtsd = "http://logi162";
		xtsite	= "396246";
		xtn2	= "<?php echo $this->seotranslation('xiti_rub'); ?>";	// level 2 site
		xtpage	= "<?php echo $currentController?>::<?php echo $currentAction?>";	//page name (with the use of :: to create chapters)
		xtdi = "";        //implication degree
		//-->
	</script>


 	<script type="text/javascript">
		var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
		document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
	</script>

	<script type="text/javascript">
		function getGAParameters(pageName) {
			siteTracker._trackPageview(pageName);
			rollupTracker._trackPageview(pageName);
		}
	</script>

	<script type="text/javascript">
		// First tracking object, for rollup reporting
                    var rollupTracker = _gat._getTracker("UA-7824708-1");
                    rollupTracker._setDomainName('.grand-marnier.com');
                    rollupTracker._trackPageview('<?php echo $currentController?>/<?php echo $currentAction?>');
                // Second tracking object, for each individual site

<?php if ($this->layout()->userLanguage == 'fr') {
?>
                    var siteTracker = _gat._getTracker("UA-7824708-3");
<?php
} else {
?>
                    var siteTracker = _gat._getTracker("UA-7824708-4");
<?php
}
?>
                    siteTracker._setDomainName('.grand-marnier.com');
                    siteTracker._trackPageview('<?php echo $currentController?>/<?php echo $currentAction?>');
        </script>

<!--<script type="text/javascript">
		//LOADING ANIMATIONS
    $(document).ready(function() {
			//LOADER
			$("#loader").fadeOut(600);
      $(".bigWrapper").animate({opacity:"1"},{duration:1000});
			$(".bgAgeChecker").animate({opacity:"0.85"},{duration:1000});

			//SITE FADE NAV
			$('.mainNav a').click(function() {
					var target = $(this).attr('href');
					$("#loader").fadeIn(600);
					$(".bigWrapper").animate({opacity:"0"},{duration:1000, complete:function() {
							window.location = target;
					}});
					return false
					});
			});
  </script>-->

        <span id="tracker">UA-7824708-4</span>
	<span id="Xiti"><?php echo $this->seotranslation('xiti_rub'); ?></span>
	<script type="text/javascript" src="/js/xtcore.js"></script>
	<noscript>
		<img width="1" height="1" alt="" src="http://logi162.xiti.com/hit.xiti?s=396246&s2=<?php echo $this->seotranslation('xiti_rub'); ?>&p=<?php echo $currentController?>::<?php echo $currentAction?>&di=&" />
	</noscript>
<?php #echo $this->seotranslation('description'); ?>
<?php #echo $this->seotranslation('xiti_rub'); ?>
<?php #echo $this->seotranslation('xiti_page'); ?>

</body>
</html>

